package com.itic.mall.system.premoney.service;

import java.util.List;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;

import com.itic.appbase.framework.common.service.CrudService;
import com.itic.mall.system.premoney.persistence.dao.PreMoneyDao;
import com.itic.mall.system.premoney.persistence.model.PreMoney;
import com.itic.mall.system.premoney.persistence.model.PreMoneyExample;
import com.itic.mall.system.premoney.persistence.vo.PreMoneyVo;


@Service
@Transactional
public class PreMoneyService
     extends CrudService<PreMoneyDao,PreMoney,PreMoneyExample> {
    @Autowired
    private PreMoneyDao preMoneyDao;

	public PreMoney getByOrderProductsId(String orderProductsId) {
		return preMoneyDao.getByOrderProductsId(orderProductsId);
	}

	public PreMoney getByOrderId(String orderId) {
		return preMoneyDao.getByOrderId(orderId);
	}

	public void editByExample(PreMoneyExample example2, PreMoney preMoney) {
		preMoneyDao.updateByExampleSelective(preMoney, example2);
	}

	public String statisTotalPreMoney(String id) {
		return preMoneyDao.statisTotalPreMoney(id);
	}

	public List<PreMoneyVo> getRepeatListGreatCount() {
		return preMoneyDao.getRepeatListGreatCount();
	}
}